Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

emit !align attributes on stores of operand pairs #40385

Merged
merged 1 commit into from
Mar 13, 2017

Conversation

arielb1
Copy link
Contributor

@arielb1 arielb1 commented Mar 9, 2017

This avoids another case of missing-align UB. cc #40373

r? @eddyb

@eddyb
Copy link
Member

eddyb commented Mar 9, 2017

@bors r+

@bors
Copy link
Contributor

bors commented Mar 9, 2017

📌 Commit 14e9313 has been approved by eddyb

@bors
Copy link
Contributor

bors commented Mar 9, 2017

🔒 Merge conflict

@alexcrichton
Copy link
Member

@bors: retry

@nrc nrc assigned eddyb Mar 9, 2017
arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 9, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
alexcrichton added a commit to alexcrichton/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
alexcrichton pushed a commit to arielb1/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
pub fn call_pkd(f: fn() -> Array) -> BigPacked {
// CHECK: [[ALLOCA:%[_a-z0-9]+]] = alloca %Array
// CHECK: call void %{{.*}}(%Array* noalias nocapture sret dereferenceable(32) [[ALLOCA]])
// CHECK: call void @llvm.memcpy.p0i8.p0i8.i64(i8* %{{.*}}, i8* %{{.*}}, i64 32, i32 1, i1 false)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This failed for me on emscripten / llvm 4.0, however I believe it may / will fail on other 32bit platforms as well:

/checkout/src/test/codegen/packed.rs:43:11: error: expected string not found in input
// CHECK: call void @llvm.memcpy.p0i8.p0i8.i64(i8* %{{.*}}, i8* %{{.*}}, i64 32, i32 1, i1 false)
          ^
/checkout/obj/build/x86_64-unknown-linux-gnu/test/codegen/packed.ll:34:2: note: scanning from here
 br label %bb1
 ^
/checkout/obj/build/x86_64-unknown-linux-gnu/test/codegen/packed.ll:42:2: note: possible intended match here
 call void @llvm.memcpy.p0i8.p0i8.i32(i8* %6, i8* %5, i32 32, i32 1, i1 false)
 ^

@alexcrichton
Copy link
Member

@bors: r-

(due to @TimNN's comment)

@alexcrichton
Copy link
Member

Looks like @TimNN is spot on

@arielb1 arielb1 force-pushed the packed-again branch 2 times, most recently from 4b75ee7 to 038ec50 Compare March 10, 2017 20:39
@arielb1
Copy link
Contributor Author

arielb1 commented Mar 10, 2017

@bors r=eddyb

@bors
Copy link
Contributor

bors commented Mar 10, 2017

📌 Commit 038ec50 has been approved by eddyb

arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 10, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
arielb1 pushed a commit to arielb1/rust that referenced this pull request Mar 11, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc rust-lang#40373

r? @eddyb
bors added a commit that referenced this pull request Mar 11, 2017
Rollup of 13 pull requests

- Successful merges: #40146, #40299, #40315, #40319, #40344, #40345, #40367, #40372, #40373, #40385, #40400, #40404, #40431
- Failed merges:
@bors
Copy link
Contributor

bors commented Mar 13, 2017

🔒 Merge conflict

@arielb1
Copy link
Contributor Author

arielb1 commented Mar 13, 2017

@bors retry

@arielb1
Copy link
Contributor Author

arielb1 commented Mar 13, 2017

@bors r-

@arielb1
Copy link
Contributor Author

arielb1 commented Mar 13, 2017

@bors r=eddyb

@bors
Copy link
Contributor

bors commented Mar 13, 2017

📌 Commit 32c9893 has been approved by eddyb

@bors
Copy link
Contributor

bors commented Mar 13, 2017

⌛ Testing commit 32c9893 with merge ddc1708...

bors added a commit that referenced this pull request Mar 13, 2017
emit !align attributes on stores of operand pairs

This avoids another case of missing-align UB. cc #40373

r? @eddyb
@bors
Copy link
Contributor

bors commented Mar 13, 2017

☀️ Test successful - status-appveyor, status-travis
Approved by: eddyb
Pushing ddc1708 to master...

@bors bors merged commit 32c9893 into rust-lang:master Mar 13, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants